import request from '@/utils/request'
/**
 * login
 * @param {*} data 表单数据
 * @returns
 */
export const login = data => request.post('/sys/login', data)
/**
 * 获取用户基本资料
 * @returns
 */
export const reqUserInfo = () => request.post('/sys/profile')
/**
 * 保存员工基本信息
 * @param {*} id 员工id
 * @returns
 */
export const reqStaffBaseInfo = id => request.get(`/sys/user/${id}`)
// 获取员工基本信息 (包含头像)
export function reqGetUserDetailById(id) {
  return request({
    method: 'get',
    url: `/sys/user/${id}`
  })
}
